package com.epam.weblibrary.repositories.book;

import com.epam.weblibrary.entities.book.Book;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

/**
 * Created by DruidKuma on 9/8/14.
 */
public interface BookRepository extends JpaRepository<Book, Long> {
    List<Book> findByAvailable(boolean available);
    Page<Book> findByAvailable(boolean available, Pageable pageable);
}
